﻿using SqlSugar;
using System;
using System.Collections.Generic;

namespace tlBasic.Core
{
    /// <summary>
    /// 系统菜单表
    /// </summary>
    [SugarTable("sys_Menu", "系统菜单表", IsDisabledUpdateAll = true)]
    public class sys_Menu: DEntityBase
    {
           
        /// <summary>
        /// 组件
        /// </summary>
         [SugarColumn(ColumnDescription = "组件")]
        public string Component { get; set; }
                            
        /// <summary>
        /// 隐藏菜单
        /// </summary>
         [SugarColumn(ColumnDescription = "隐藏菜单")]
        public bool HideInMenu { get; set; }
                
        /// <summary>
        /// 链接
        /// </summary>
         [SugarColumn(ColumnDescription = "链接")]
        public string Href { get; set; }
                
        /// <summary>
        /// 图标
        /// </summary>
         [SugarColumn(ColumnDescription = "图标")]
        public string Icon { get; set; }
                        
        /// <summary>
        /// 名称
        /// </summary>
         [SugarColumn(ColumnDescription = "名称")]
        public string Name { get; set; }
                
        /// <summary>
        /// 不使用缓存
        /// </summary>
         [SugarColumn(ColumnDescription = "不使用缓存")]
        public bool NotCache { get; set; }
                
        /// <summary>
        /// 父Id
        /// </summary>
         [SugarColumn(ColumnDescription = "父Id")]
        public long ParentId { get; set; }
                
        /// <summary>
        /// 路由
        /// </summary>
         [SugarColumn(ColumnDescription = "路由")]
        public string Path { get; set; }

        /// <summary>
        /// 支持参数
        /// </summary>
        [SugarColumn(ColumnDescription = "支持参数")]
        public bool Props { get; set; }

        /// <summary>
        /// 动态标题
        /// </summary>
        [SugarColumn(ColumnDescription = "动态标题")]
        public bool PropsTitle { get; set; }

        /// <summary>
        /// 动态参数详情
        /// </summary>
        [SugarColumn(ColumnDescription = "动态参数详情")]
        public string PropsInfo { get; set; }
        /// <summary>
        /// 唯一权限key
        /// </summary>
        [SugarColumn(ColumnDescription = "唯一权限key")]
        public string PermissionKey { get; set; }
                
        /// <summary>
        /// 排序
        /// </summary>
         [SugarColumn(ColumnDescription = "排序")]
        public int Sort { get; set; }
                
        /// <summary>
        /// 标题
        /// </summary>
         [SugarColumn(ColumnDescription = "标题")]
        public string Title { get; set; }
                
        /// <summary>
        /// 类型
        /// </summary>
         [SugarColumn(ColumnDescription = "类型")]
        public MenuType Type { get; set; }

        /// <summary>
        /// 系统菜单
        /// </summary>
        [SugarColumn(ColumnDescription = "系统菜单")]
        public bool IsSystem { get; set; }

        [SugarColumn(IsIgnore = true)]
        public bool _showChildren { get; set; } = false;
        /// <summary>
        /// 菜单子项
        /// </summary>
        [SugarColumn(IsIgnore = true)]
        public List<sys_Menu> children { get; set; } = new List<sys_Menu>();

    }
}